package com.banyuan.项目测试;

import java.awt.EventQueue;

import javax.swing.JFrame;
import javax.swing.JButton;
import javax.swing.JTextArea;
import javax.swing.JLabel;
import javax.swing.JComboBox;
import javax.swing.DefaultComboBoxModel;
import javax.swing.JTextPane;
import java.awt.Font;
import javax.swing.JTextField;
import java.awt.Color;
import java.awt.SystemColor;
import javax.swing.JCheckBox;
import java.awt.event.ActionListener;
import java.awt.event.ActionEvent;

public class Client {

	private JFrame frame;
	private JTextField textField;

	/**
	 * Launch the application.
	 */
	public static void main(String[] args) {
		EventQueue.invokeLater(new Runnable() {
			public void run() {
				try {
					Client window = new Client();
					window.frame.setVisible(true);
				} catch (Exception e) {
					e.printStackTrace();
				}
			}
		});
	}

	/**
	 * Create the application.
	 */
	public Client() {
		initialize();
	}

	/**
	 * Initialize the contents of the frame.
	 */
	private void initialize() {
		frame = new JFrame();
		frame.setTitle("半圆聊天室服务端");
		frame.setBounds(100, 100, 529, 505);
		frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
		frame.getContentPane().setLayout(null);
		
		JButton btnNewButton = new JButton("用户设置");
		btnNewButton.addActionListener(new ActionListener() {
			public void actionPerformed(ActionEvent e) {
			}
		});
		btnNewButton.setBounds(6, 6, 96, 29);
		frame.getContentPane().add(btnNewButton);
		
		JButton btnNewButton_1 = new JButton("登陆");
		btnNewButton_1.setBounds(114, 6, 96, 29);
		frame.getContentPane().add(btnNewButton_1);
		
		JButton btnNewButton_2 = new JButton("退出");
		btnNewButton_2.setBounds(222, 6, 96, 29);
		frame.getContentPane().add(btnNewButton_2);
		
		JTextArea textArea = new JTextArea();
		textArea.setBounds(6, 40, 517, 331);
		frame.getContentPane().add(textArea);
		
		JLabel label = new JLabel("发送消息至：");
		label.setBounds(6, 383, 83, 29);
		frame.getContentPane().add(label);
		
		JComboBox comboBox = new JComboBox();
		comboBox.setModel(new DefaultComboBoxModel(new String[] {"所有人"}));
		comboBox.setBounds(84, 383, 110, 27);
		frame.getContentPane().add(comboBox);
		
		JLabel label_1 = new JLabel("发送消息：");
		label_1.setBounds(6, 422, 83, 19);
		frame.getContentPane().add(label_1);
		
		JButton btnNewButton_3 = new JButton("发送");
		btnNewButton_3.setBounds(406, 418, 117, 29);
		frame.getContentPane().add(btnNewButton_3);
		
		textField = new JTextField();
		textField.setBounds(61, 418, 345, 29);
		frame.getContentPane().add(textField);
		textField.setColumns(10);
		
		JTextPane textPane = new JTextPane();
		textPane.setText("当前在线人数0");
		textPane.setBackground(SystemColor.window);
		textPane.setForeground(Color.LIGHT_GRAY);
		textPane.setBounds(6, 453, 507, 19);
		frame.getContentPane().add(textPane);
		
		JButton btnNewButton_2_1 = new JButton("注销");
		btnNewButton_2_1.setBounds(330, 6, 96, 29);
		frame.getContentPane().add(btnNewButton_2_1);
		
		JLabel label_2 = new JLabel("表情：");
		label_2.setBounds(222, 383, 83, 29);
		frame.getContentPane().add(label_2);
		
		JComboBox comboBox_1 = new JComboBox();
		comboBox_1.setModel(new DefaultComboBoxModel(new String[] {"微笑的"}));
		comboBox_1.setBounds(261, 383, 110, 27);
		frame.getContentPane().add(comboBox_1);
		
		JCheckBox chckbxNewCheckBox = new JCheckBox("悄悄话");
		chckbxNewCheckBox.setBounds(436, 383, 77, 23);
		frame.getContentPane().add(chckbxNewCheckBox);
	}
}
